

<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  
  <title>在 Flask 中使用 Celery &mdash; using celery with flask 1.00 documentation</title>
  

  
  

  
  <link href='https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic|Roboto+Slab:400,700|Inconsolata:400,700&subset=latin,cyrillic' rel='stylesheet' type='text/css'>

  
  
    

  

  
  
    <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  

  
    <link rel="top" title="using celery with flask 1.00 documentation" href="#"/>
        <link rel="next" title="在 Flask 中使用 Celery" href="first.html"/> 

  
  <script src="https://cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js"></script>

</head>

<body class="wy-body-for-nav" role="document">

  <div class="wy-grid-for-nav">

    
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-nav-search">
        
          <a href="#" class="fa fa-home"> using celery with flask</a>
        
        
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>
      </div>

      <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
        
          
          
              <ul>
<li class="toctree-l1"><a class="reference internal" href="first.html">在 Flask 中使用 Celery</a><ul>
<li class="toctree-l2"><a class="reference internal" href="first.html#id1">什么是 Celery?</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id2">致行动派读者</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id3">Flask 和 Celery 一起工作</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id5">简单例子：异步发送邮件</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id6">复杂例子：显示状态更新和结果</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id8">运行示例</a></li>
</ul>
</li>
</ul>

          
        
      </div>
      &nbsp;

    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">

      
      <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
        <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
        <a href="#">using celery with flask</a>
      </nav>


      
      <div class="wy-nav-content">
        <div class="rst-content">
          <div role="navigation" aria-label="breadcrumbs navigation">
  <ul class="wy-breadcrumbs">
    <li><a href="#">Docs</a> &raquo;</li>
      
    <li>在 Flask 中使用 Celery</li>
      <li class="wy-breadcrumbs-aside">
        
          <a href="_sources/index.txt" rel="nofollow"> View page source</a>
        
      </li>
  </ul>
  <hr/>
</div>
          <div role="main" class="document">
            
  <div class="section" id="flask-celery">
<h1>在 Flask 中使用 Celery<a class="headerlink" href="#flask-celery" title="Permalink to this headline">¶</a></h1>
<p>翻译者注：原文名为：<a class="reference external" href="http://blog.miguelgrinberg.com/post/using-celery-with-flask">Using Celery With Flask</a> ，作者是 <strong>Miguel Grinberg</strong> 。</p>
<p>目录:</p>
<div class="toctree-wrapper compound">
<ul>
<li class="toctree-l1"><a class="reference internal" href="first.html">在 Flask 中使用 Celery</a><ul>
<li class="toctree-l2"><a class="reference internal" href="first.html#id1">什么是 Celery?</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id2">致行动派读者</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id3">Flask 和 Celery 一起工作</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id5">简单例子：异步发送邮件</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id6">复杂例子：显示状态更新和结果</a></li>
<li class="toctree-l2"><a class="reference internal" href="first.html#id8">运行示例</a></li>
</ul>
</li>
</ul>
</div>
</div>


          </div>
          <footer>
  
    <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
      
        <a href="first.html" class="btn btn-neutral float-right" title="在 Flask 中使用 Celery">Next <span class="fa fa-arrow-circle-right"></span></a>
      
      
    </div>
  

  <hr/>

  <div role="contentinfo">
    <p>
        &copy; Copyright 2015, miguel.
    </p>
  </div>

  Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
  
</footer>
        </div>
      </div>

    </section>

  </div>
  


  

    <script type="text/javascript">
        var DOCUMENTATION_OPTIONS = {
            URL_ROOT:'./',
            VERSION:'1.00',
            COLLAPSE_INDEX:false,
            FILE_SUFFIX:'.html',
            HAS_SOURCE:  true
        };
    </script>
      <script type="text/javascript" src="_static/jquery.js"></script>
      <script type="text/javascript" src="_static/underscore.js"></script>
      <script type="text/javascript" src="_static/doctools.js"></script>

  

  
  
    <script type="text/javascript" src="_static/js/theme.js"></script>
  

  
  
  <script type="text/javascript">
      jQuery(function () {
          SphinxRtdTheme.StickyNav.enable();
      });
  </script>
   

</body>
</html>